package com.lixinyue.test10;

/**
 * @program: 11.12
 * @description:
 * @author: 李鑫月
 * @create: 2021-11-19 09:21
 **/
abstract class A{
    private String name;
    public int age;
    public A(String name){
        this.name=name;
    }
    abstract  void draw();
    String getName(){
        return this.name;
    }
    void func(){
        System.out.println("*********");
    }
}
class B extends A{
    public B(String name){
        super(name);
    }
    @Override
    void draw() {
        System.out.println("#####");

    }
}
public class Testdemo1 {
    public static void main(String[] args) {
        B b=new B("李鑫月");
        System.out.println(b.getName());
        b.func();
    }

}
